package com.qqtech.qquan.circle.service;

import javax.annotation.Resource;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.stereotype.Service;

import com.qqtech.core.frame.dao.BaseDao;
import com.qqtech.core.frame.service.BaseServiceImpl;
import com.qqtech.qquan.circle.dao.CircleInfoDao;
import com.qqtech.qquan.circle.model.CircleInfo;
import com.qqtech.qquan.circle.model.CircleInfoQuery;
import com.qqtech.qquan.circle.model.CircleInfoVo;

@Service
public class CircleInfoServiceImpl extends BaseServiceImpl<CircleInfo>
		implements CircleInfoService {
	public static final Logger log = LoggerFactory.getLogger(CircleInfoServiceImpl.class);
	
	@Resource
	private CircleInfoDao circleInfoDao;

	@Override
	protected BaseDao<CircleInfo> getBaseDao() {
		return circleInfoDao;
	}
	
	@Override
	public void increasePv(Integer circleId) {
		circleInfoDao.increasePv(circleId, 1);
	}
	
	@Override
	public Page<CircleInfoVo> queryListBaseInfo(CircleInfoQuery query, Pageable pageable) {
		return circleInfoDao.queryListBaseInfo(query, pageable);
	}
}